package nl.infodation.emr.psrefdata.entity;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.OneToOne;
import javax.persistence.Table;

@Entity
@Table(name="offertype")
public class Offer implements Serializable {
	private static final long serialVersionUID = 1L;
	
	@Id
	@Column(name = "primaryKey")
	@GeneratedValue(strategy=GenerationType.AUTO)
	private long primaryKey;
	
	@Column(name = "category")
	private String category;
	
	@Column(name = "offerId")
	private long offerId;

	@OneToOne
	@JoinColumn(name="Offers_fk", referencedColumnName="offers_primaryKey")
	private SalesSupport salesSupport;
	
	public String getCategory() {
		return category;
	}

	public void setCategory(String category) {
		this.category = category;
	}

	public long getPrimaryKey() {
		return primaryKey;
	}

	public SalesSupport getSalesSupport() {
		return salesSupport;
	}

	public void setSalesSupport(SalesSupport salesSupport) {
		this.salesSupport = salesSupport;
	}

	public static long getSerialversionuid() {
		return serialVersionUID;
	}
	
	public void setPrimaryKey(long primaryKey) {
		this.primaryKey = primaryKey;
	}

	public long getOfferId() {
		return offerId;
	}

	public void setOfferId(long offerId) {
		this.offerId = offerId;
	}
}
